home *** CD-ROM | disk | FTP | other *** search
/ SGI Hot Mix 17 / Hot Mix 17.iso / HM17_SGI / research / lib / gauss_pdf.pro < prev    next >
Text File  |  1997-07-08  |  2KB  |  63 lines

  1. ;$Id: gauss_pdf.pro,v 1.3 1997/01/15 03:11:50 ali Exp $
  2. ;
  3. ; Copyright (c) 1994-1997, Research Systems, Inc.  All rights reserved.
  4. ;       Unauthorized reproduction prohibited.
  5. ;+
  6. ; NAME:
  7. ;       GAUSS_PDF
  8. ;
  9. ; PURPOSE:
  10. ;       This function computes the probabilty (p) such that:
  11. ;                   Probability(X <= v) = p
  12. ;       where X is a random variable from the standard Gaussian (Normal) 
  13. ;       distribution with a mean of 0.0 and a variance of 1.0
  14. ;
  15. ; CATEGORY:
  16. ;       Statistics.
  17. ;
  18. ; CALLING SEQUENCE:
  19. ;       Result = Gauss_Pdf(V)
  20. ;
  21. ; INPUTS:
  22. ;       V:    A scalar of type integer, float or double that specifies
  23. ;             the cutoff value.
  24. ;
  25. ; EXAMPLES:
  26. ;       Compute the probability that a random variable X, from the
  27. ;       standard Gaussian (Normal) distribution, is less than or equal 
  28. ;       to 2.44. The result should be 0.992656
  29. ;         result = gauss_pdf(2.44)
  30. ;
  31. ;       Compute the probability that a random variable X, from the 
  32. ;       standard Gaussian (Normal) distribution, is less than or equal 
  33. ;       to 10.0 and greater than or equal to 2.0. The result should be
  34. ;       0.0227501 [i.e. Probability(2.0 <= X <= 10.0)]
  35. ;         result = gauss_pdf(10.0) - gauss_pdf(2.0)
  36. ;
  37. ;       Compute the probability that a random variable X, from the 
  38. ;       Gaussian (Normal) distribution with a mean of 0.8 and a variance 
  39. ;       of 4.0, is less than or equal to 2.44. The result should be 
  40. ;       0.793892
  41. ;         result = gauss_pdf( (2.44 - 0.80)/sqrt(4.0) )
  42. ;
  43. ; PROCEDURE:
  44. ;       GAUSS_PDF calls GAUSSINT() to evaluate the Gaussian integral.
  45. ;       This function was included to provide consistency with the 
  46. ;       other probability functions: CHISQR_PDF(), F_PDF(), and T_PDF().
  47. ;
  48. ; REFERENCE:
  49. ;       APPLIED STATISTICS (third edition)
  50. ;       J. Neter, W. Wasserman, G.A. Whitmore
  51. ;       ISBN 0-205-10328-6
  52. ;
  53. ; MODIFICATION HISTORY:
  54. ;       Written by:   GGS, RSI, July 1994
  55. ;-
  56.  
  57. function gauss_pdf, v
  58.  
  59.   on_error, 2  ;Return to caller if error occurs.
  60.   return, gaussint(v)
  61.  
  62. end
  63.